<?php
/**
 * Created by PhpStorm.
 * User: 15814
 * Date: 2018/10/9
 * Time: 17:04
 */
include "config.php";
$sql="DELETE FROM `goodsinfo` WHERE `gId`=?  AND `uId`=?";
$res=$conn->prepare($sql);
$res->bind_param("ii",$_POST["gId"],$_POST["uId"]);
$res->execute();
if ($res->affected_rows>=1){
    print_r(json_encode(array("stu"=>1,"msg"=>"删除成功")));
}
else{
    print_r(json_encode(array("stu"=>1,"msg"=>"删除失败")));
}